<include file="Public:header" />
<div class="container">
  <div class="mainbody"> <include file="Public:mallmenu" />
    <div class="rig_lm03">
      <div class="title" ><img src="{$Think.config.static_path}images/listicon.jpg" class="icon" >
        <h2>城市列表</h2>
        <form method="POST" action="" style="margin-left:100px;">
          <input type="text"  class="searcheTxt" placeholder="请输入名称" name="keys" id="keys" value="<?php echo $_REQUEST['keys']?>">
          <button type="button" onclick="changeSelect()" class="btn btn-primary btn-sm"><span class="glyphicon glyphicon-search"></span> 搜索</button>
        </form>
        
      </div>
      <div class="detail">
        <div id="tabCot_product_1" class="tabCot" >
          <table cellspacing="0" cellpadding="0" width="100%" border="0" class="tabindex table-hover">
            <tbody>
              <tr>
			    <th>编号</th>
                <th>城市名</th>
                <th>电话</th>
                <th>地址</th>
                <th>创建时间</th>
                 <th style="width:400px;">查询操作</th>
                <th style="width:300px;">添加、修改操作</th>
              </tr>
              <volist name="list" id="vo">
                <tr>
				  <td>{$vo.id}</td>
                  <td >
                   {$vo.title}
                  </td>
                  <td>{$vo.tel}</td>
                  <td>{$vo.address}</td>
                 
                   <td>{$vo.ctime}</td>
				 
                   <td>
						 <a href="__URL__/setconfig?cityid={$vo.id}" title="查询商户商品">商城配置</a>&nbsp;|&nbsp; 
                 		 <a href="__URL__/productList?cityid={$vo.id}" title="查询商户商品">商品管理</a>&nbsp;|&nbsp; 
                 		 <a href="__URL__/order?cityid={$vo.id}" title="查询商户订单">订单管理</a>
                   </td>
                  <td>
                  	
						<a href="__URL__/addcity?id={$vo.id}" title="修改">修改</a>&nbsp;|&nbsp; 
						<a href="#" title="添加商户用户">删除</a>
						</td>
                </tr>
              </volist>
            </tbody>
          </table>
          
          <div class="manu">
                        {$page}
                </div>
        </div>
      </div>
    </div>
  </div>
</div>
<include file="Public:footer" /> 
<script type="text/javascript">
$(function(){
	$('#city').addClass('rig_seleli');
	$("tr:odd").addClass("even");
	$("tr:even").addClass("odd");
	});
	
function changeSelect() {
	var keys = $('#keys').val();
	var userType = $('#userType').val();
    location.href = "__URL__/userList?keys=" + keys+"&userType="+userType+"&id=<?php echo $_GET['id']?>" ;
}


function confirmDelete(id){
if (confirm("确认要删除这条数据吗？")) {
       location.href="__URL__/delete?id="+id;
     }
}

function setUserOrder(id){
	var gorder = $('#gorder_'+id).val();
	$.ajax({

             type: "GET",

             url: "__URL__/setUserOrder?id="+id+"&gorder="+gorder,

             data: '',

             dataType: "json",

             success: function(data){
				location.replace(location.href);
                  }
		
         });
}

</script>